<?php

use Illuminate\Http\Request;

/*
|--------------------------------------------------------------------------
| API Routes
|--------------------------------------------------------------------------
|
| Here is where you can register API routes for your application. These
| routes are loaded by the RouteServiceProvider within a group which
| is assigned the "api" middleware group. Enjoy building your API!
|
*/

// 暂时注释larvel原始api
//Route::middleware('auth:api')->get('/user', function (Request $request) {
//    return $request->user();
//});

// 获取token
Route::any('/getToken', 'AdapterApiController@getToken');
// 获取API类别
Route::any('/getcate', 'AdapterApiController@getcate');
// 获取API数量
Route::any('/getcount', 'AdapterApiController@getcount');
Route::any('/cateApis', 'AdapterApiController@cateApis');
Route::any('/rewriteapi', 'AdapterApiController@rewriteapi');
Route::any('/addApi', 'AdapterApiController@addApi');
Route::any('/getApiDetail', 'AdapterApiController@getApiDetail');
Route::any('/editApi', 'AdapterApiController@editApi');


// api 主入口
Route::any('/index', 'AdapterApiController@index');
// 适配文档API 主入口
Route::any('/manage/index/index', 'AdapterApiController@index');
//上传文件
Route::any('/manage/index/upload', 'AdapterApiController@upload');
